/**
import { Comments } from '@/components/Comments';
 * Created by Administrator on 2018/11/3.
 */
const Comments = require("../models/comments");
const User = require("../models/users");
/**
 * 增加公司信息
 */

module.exports = function (data, req, response) {

  User.findOne({
    username: data.name
  }).then(function (res) {
    // console.log(res);

    Comments.find({
      recv: res.company
    }).then(function (res) {
      response.json({
        status: 0,
        data: res
      })
    })
  });
}
